<?php

namespace GatewayChat\tool;

use GatewayClient\Gateway;

class Message
{
    static function send(string|array $message, $port = 8101)
    {
        Gateway::$registerAddress = '127.0.0.1:' . $port;
        if (is_array($message)) {
            $message = json_encode($message, true);
        }
        Gateway::sendToAll('admin');
    }
}